package com.iflytek.sort;

import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Reducer;

import java.io.IOException;

public class BestSortSumReducer extends Reducer<BestCountBean, Text,Text, BestCountBean> {
    @Override
    protected void reduce(BestCountBean key, Iterable<Text> values, Context context) throws IOException, InterruptedException {
        // 读取到评论数
        Text outKey = values.iterator().next();
        context.write(outKey,key);
    }
}